//
//  SHBaseCollectionViewCell.m
//  UI_CarHome
//
//  Created by dllo on 15/11/7.
//  Copyright (c) 2015年 沈浩. All rights reserved.
//

#import "SHBaseCollectionViewCell.h"
#import "SHHandle.h"
#define COLLECTIONCELLBACKGROUND [SHSingleton shareSingletion].isNight ? [UIColor colorWithWhite:0.044 alpha:1.000] : [UIColor colorWithWhite:0.907 alpha:1.000]
@implementation SHBaseCollectionViewCell

- (instancetype)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];
    if (self) {
        self.contentView.backgroundColor = COLLECTIONCELLBACKGROUND;
        [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(isNight:) name:@"isNight" object:nil];
    }
    return self;
}

- (void)isNight:(NSNotification *)notification {
    self.contentView.backgroundColor = COLLECTIONCELLBACKGROUND;
//    NSArray *arr = self.contentView.subviews;
//    for (NSInteger i = 0; i < arr.count; i++) {
//        if ([arr[i] isKindOfClass:[UILabel class]]) {
//            UILabel *label = arr[i];
//            label.textColor = TEXTCOLOR;
//        }
//    }
}
@end
